package com.xiaoger.async.async;

/**
 * 异步方法自定义异常
 */
public class AsyncException extends RuntimeException {
    private static final long serialVersionUID = 1L;

    /**
     * 异常返回结果
     */
    private Object data;

    public Object getData() {
        return data;
    }

    public AsyncException(String message) {
        super(message);
    }

    public AsyncException(Throwable cause) {
        super(cause);
    }

    public AsyncException(String message, Throwable cause) {
        super(message, cause);
    }

    public AsyncException(String message, Object data) {
        super(message);
        this.data = data;
    }

}
